# 集合间的数学运算
s1={1,2,3,5,6}
s2={2,4,5,8}

# 交集
print(s1.intersection(s2))

# 并集
print(s1.union(s2))

# 差集
print(s1.difference(s2))
print(s2.difference(s1))

# 对称差集
print(s1.symmetric_difference(s2))
print(s2.symmetric_difference(s1))